@(title: String)(content: Html)
@import controllers.user.UserController
@import models.Category
<!DOCTYPE html>

<html>
    <head>
        <title>@title</title>
				<link rel="stylesheet" media="screen" href="@routes.Assets.at("stylesheets/bootstrap.min.css")">
        <link rel="stylesheet" media="screen" href="@routes.Assets.at("stylesheets/bootstrap.css")">
        <link rel="stylesheet" media="screen" href="@routes.Assets.at("stylesheets/style.css")" />

        <link rel="shortcut icon" type="image/png" href="@routes.Assets.at("images/favicon.png")">

    </head>
    
    <body style="padding-top: 50px; paddig-bottom:70px;">
    <!--head-------------------------------->
		<div class="navbar-wrapper">
      <div class="container">
        <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
          <div class="container">
            <div class="navbar-header">
              <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                <span class="sr-only">Toggle navigation</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
              </button>
              <a href="#" class="navbar-brand">BordeShop</a>
            </div>
            <div class="navbar-collapse collapse">
              <ul class="nav navbar-nav">
								<li><a href="/home">Home</a></li>
                <li><a href="/tasks">Task</a></li>
                <li><a href="/product/list">Product</a></li>
                <li><a href="/advertisement">Advertisement</a></li>
                <li class="dropdown">
                  <a href="#" class="dropdown-toggle" data-toggle="dropdown">User <b class="caret"></b></a>
                  <ul class="dropdown-menu">
					@if(session.get("currentUserEmail") == null){
                    <li><a href='/users/logIn'>logIn</a></li>
                    <li><a href='/users/signUp'>signUp</a></li>
					}else{
                    <li><a href='/users/myOrders'>Purchase history</a></li>
					<li><a href="/users/chgPsw">Change Password</a></li>
                    <li class="divider"><hr /></li>
                    <li><a href='/users/logOut'>logOut</a></li>
					}
                  </ul>
                </li><!--end of Users-->
				<li class="dropdown">
				@if(session.get("currentUserEmail") != null && UserController.getCurrentUser().getPriv("worker")){
					@if(UserController.getCurrentUser().getRole().getName().equals("admin")){
						<a href="#" class="dropdown-toggle" data-toggle="dropdown">Admin <b class="caret"></b></a>
						<ul class="dropdown-menu">
							<li><a href='/users'>deleteUser</a></li>
					}else{
					<a href="#" class="dropdown-toggle" data-toggle="dropdown">Employee <b class="caret"></b></a>
					<ul class="dropdown-menu">
					}
						<li><a href='/product/newProduct'>addProduct</a></li>
						<li><a href='/categories'>addCategory</a></li>
          </ul>
				 }
                </li>
          </ul>
			  <a href='/cart'><img height="30px" width="30px" class="navbar-form navbar-right" src="@routes.Assets.at("images/cart.png")" /></a>
			  <form action="/product/search" class="navbar-form navbar-right" role="search">
				<div class="form-group">
					<input type="text" class="form-control" name="query" value="" placeholder="Search in Prods...">
				</div>
			  </form>
            </div>
          </div>
        </div>

      </div>
		</div><!--end Of navBar-->
   

    <!--content-------------------------------->
    <div id="content">
        @content
    </div>
    
    <!--foot-------------------------------->
    <nav class="navbar-fixed-bottom" role="navigation">
		  <div id="footer">
            Rf 2013 (c) <a href='/'><font color="white">play</a> @session.get("currentUserEmail")</font><br />
    	</div>
		</nav>
  <script src="https://code.jquery.com/jquery-1.10.2.min.js"></script>
	<script src="@routes.Assets.at("javascripts/bootstrap.js")"></script>  
	</body>
</html>
